package org.pzy.java.proxy.static_proxy;

import org.pzy.java.proxy.SmsService;

/**
 * @Author: DRevelation
 * @Date: 2022/2/23 10:34
 * 静态代理
 */
public class SmsProxy implements SmsService {

    private SmsService smsService;

    public SmsProxy(SmsService smsService) {
        this.smsService = smsService;
    }

    @Override
    public String send(String message) {
        System.out.println("before method send");
        smsService.send(message);
        System.out.println("after method send");
        return null;
    }

}
